//package cn.sunjinxin.trade.application.work.node;
//
//import cn.hutool.core.lang.Assert;
//import cn.sunjinxin.trade.application.work.pipeline.PreOrderValidateWorkHandler;
//import cn.sunjinxin.trade.application.work.pipeline.PreOrderValidateWorkHandlerContext;
//import cn.sunjinxin.trade.client.api.request.OrderCreateRequest;
//import cn.sunjinxin.trade.client.api.request.OrderValidateRequest;
//
//import java.util.Date;
//
///**
// * @author issavior
// */
//public class BaseBusinessValidateNode implements PreOrderValidateWorkHandler {
//
//    @Override
//    public void validate(OrderValidateRequest request, PreOrderValidateWorkHandlerContext validateWorkHandlerContext) {
//        Assert.isTrue(request.getTraveler().size() == request.getBuyQuantity(), "购买数量和出行人数量不一致");
//        Assert.isTrue(request.getTravelerTime().getTime() > new Date().getTime() + 60 * 60 * 24 * 1000, "出行时间异常");
//
//        validateWorkHandlerContext.validate(request);
//    }
//
//    @Override
//    public void validate(OrderCreateRequest request, PreOrderValidateWorkHandlerContext validateWorkHandlerContext) {
//
//    }
//}
